//
//  Define.h
//  Runone
//
//  Created by runone01 on 16/8/2.
//  Copyright © 2016年 runone. All rights reserved.
//

#ifndef Define_h
#define Define_h

////SystemCode
#define DefaultSystemCode @"GuangleHighway"

//内网开发专用 登录接口
#define GetLOGINURL @"http://192.168.1.200:8088/OAuth/Token"
//内网开发专用 API URL
#define GetAPIURL @"http://192.168.1.200:8090"


//内网测试专用 登录接口
//#define GetLOGINURL @"http://192.168.1.138:8088/OAuth/Token"
//内网测试专用 API URL
//#define GetAPIURL @"http://192.168.1.138:8090"
//
//外网发布专用 登录接口
//#define GetLOGINURL @"http://120.76.152.148:8088/OAuth/Token"
//外网发布专用 API URL
//#define GetAPIURL @"http://120.76.152.148:8090"

//外网发布专用 登录接口
 //内网测试WebSocketUrl
//#define GetWSURL @"ws://192.168.1.138:6070"
//内网开发WebSocketUrl
#define GetWSURL @"ws://192.168.1.200:6070"
////外网开发WebSocketUrl
//#define GetWSURL @"ws://120.76.152.148:6070"


//拿到用户账号
#define GetRememberUserName [[AppLocalManager sharedManager]getDataByKey:@"RememberUserName"]

//拿到用户密码
#define GetRememberPassWord [[AppLocalManager sharedManager]getDataByKey:@"RememberPassWord"]
#define client_id @"APP"

#define client_secret @"RUNONE_APP"

//刷新token
#define  refreshClient_id  @"RUNONE"

#define refreshClient_secrect @"REFRESHTOKEN"

//记录登录Token
#define ACCESS_TOKEN @"access_token"

//记录刷新Token
#define REFRESH_TOKEN @"refresh_token"

//拿到登录Token
#define GETACCESS_TOKEN [[AppLocalManager sharedManager] getDataByKey:ACCESS_TOKEN]

//拿到刷新Token
#define GETREFRESH_TOKEN [[AppLocalManager sharedManager] getDataByKey:REFRESH_TOKEN]

//token过期
#define TOKENOUTOFDATE   

//路政push
#define LUZHENGCAR [[AppLocalManager sharedManager] getDataByKey:@"HighwaysVehicleAlarm"];
//行政push
#define XINZHENGCAR [[AppLocalManager sharedManager] getDataByKey:@"AdministrativeVehicleAlarm"];
//交通push
#define JIAOTONGGCAR [[AppLocalManager sharedManager] getDataByKey:@"TrafficAccidentAlarm"];
//施工push
#define SHIGONGCAR [[AppLocalManager sharedManager] getDataByKey:@"ConstructionEventAlarm"];
//是否登录
#define ISLOGIN @"isLogin"

//高德Key
#define GETGAODEPAIKEY @"b62bcc929ee8837e890fc61856b6c855"


//// 临时内网
//#define GetAPIURL @"http://192.168.1.120:8090"

//权限
#define GetSysRightGroupCode  [GetAPIURL stringByAppendingString:@"/api/SystemData"]

#define  SYSRIGHTGROUPCODE    @"UserUID"

#define GetSys_RightCode        [[AppLocalManager sharedManager] getDataByKey:SYSRIGHTGROUPCODE]

//用户UID
#define  SYSUSERUID        @"DataValue"

//设备.../api/VehicleData
#define GetDeviceDataURL  [GetAPIURL stringByAppendingString:@"/api/DeviceData"]

//车辆管理-录入
#define GetCarManagerEnterMessageURL  [GetAPIURL stringByAppendingString:@"/api/VehicleData"]

//内部车辆
#define GetVehicleDataURL  [GetAPIURL stringByAppendingString:@"/api/VehicleData"]

//获取当前所有事件URL
#define GetEventDataURL [GetAPIURL stringByAppendingString:@"/api/EventData"]

//获取指定车辆，时间范围内的历史轨迹
#define GetCarHistoryURL [GetAPIURL stringByAppendingString:@"/api/VehicleData"]

// 所有内部车辆的URL
#define GetIntVclBaseInfo [GetAPIURL stringByAppendingString:@"/api/VehicleData"]


//高速干道
#define HighWayRoadArrayKey @"HighWayRoadArrayKey"

#define CURRENTEVENTARRAYKEY @"CurrentEventArrayKey"

//两客一危
#define GetAllLastestVehicleDynamicURL [GetAPIURL stringByAppendingString:@"/api/VehicleData"]

//个人信息URL
#define GetCurrentDutyPersonalName [GetAPIURL stringByAppendingString:@"/api/SystemData"]

// 消息通知
#define RegisterNotify(_name, _selector)                    \
[[NSNotificationCenter defaultCenter] addObserver:self  \
selector:_selector name:_name object:nil];

#define RemoveNofify            \
[[NSNotificationCenter defaultCenter] removeObserver:self];

#define SendNotify(_name, _object)  \
[[NSNotificationCenter defaultCenter] postNotificationName:_name object:_object];

#endif /* Define_h */
